	/**
   		* 加载数据
   		*/
   		function getTodoData(messageType,id,history_bz){
   			var pageNo=$("#pageNo"+id).val(); 
   			var pageSize=$("#pageSize"+id).val();
   			
   			$("#"+id).empty();
   			var list=null;
   			var pager=null;
			$.getJSON(Com_Parameter.ContextPath + "/common/getDataList?s_bean=msgDataService&status="
						+messageType+"&history_bz="+history_bz+"&pageNo="+pageNo+"&pageSize="+pageSize, function(data) {
				$.each(data, function(index, val) {  
					list=val.list; 
					pager=val;
				});
				
				if(list==null || list==""){
					  $("#"+id).append(" <div class='tabs_3'><div class='tabs_text'>暂无待办</div></div>");
					  return;
				}
				//遍历集合
				$.each(list, function(index, val) { 
					//跳转链接
				     var title_link="";
				     //待办类型
					 var type=val.messageType;
			    	 title_link=contextPath+"/sys/msg/view/"+val.id; 
				     //标题
				     var title= val.title;
				     if(title!=null && title!=""){
					      if(title.length>30){
					    	  title=title.substr(0,30)+"...";
					      }
				     }else{
				    	 title="";
				     }
				     //内容
				      var content ="";
				     if(val.content!=null && val.content!=""){
				    	 if(val.content.length>150){
				    	  content=val.content.substr(0,150)+"...";
				    	 }else{
				    		 content=val.content;
				    	 }
				     } 
				     //内容标示（0：内容为content，1链接到url内容）
				     //var contentTypeFlag=val.contentTypeFlag;
				      
				     //根据资源类型加载图片
				     var source=val.source;
				     if(source==null || source==""){
				    	 source="pic_1";
				     }
				     
				     var img=staticPath+"/images/"+source+".gif"; 
				     //动态加载数据
				     $("#"+id).append(" <div class='tabs_3'>" +
						     			"	<div class='col-sm-1 tabs_4'><img src='"+img+"' width='49px' height='49px'></div>" +
			                            "   <div class='col-sm-10'>" +
				                            "   <div class='tabs_title'><a href='"+title_link+"' title='"+val.title+"'  target='_blank'  onclick=btn_read('"+val.messageType+"')>"+title+"</a></div>" +
				                            "   <div class='tabs_text'>"+content+"</div>" +
					                            "   <div class='tabs_func'>" +
					                            "      <div class='col-sm-5 tabs_Time'>"+val.createDate +"</div>" +
					                       /*     "      <div class='col-sm-7 text_red'><a href='#' class='text-danger'>阅读</a>&nbsp;|&nbsp;<a href='#' class='text-danger'>同意</a>&nbsp;|&nbsp;"+
					                           "<a href='#' class='text-danger'>待审批</a>&nbsp;|&nbsp;<a href='#' class='text-danger'>已审批</a>" +
					                           "      </div>" + */
					                           "  </div>" +
			                           "  </div>" +
				     				"</div>");  
				}); 
				var pageNo=pager.pageNo;
				var pageSize=pager.pageSize;
				var total=pager.total;  
				var pageTotal= (total + pageSize - 1) / pageSize; // 计算总页数
				pageTotal=Math.floor(pageTotal);
				if (pageNo > pageTotal) {
					pageNo = pageTotal;
				}
				if (pageNo < 1) {
					pageNo = 1;
				}
				var str="";
				if(pageNo==1){ 
					str="<li class=\"disabled\"><a href=\"javascript:\">« 上一页</a></li>\r\n";
				}else{
					str="<li><a href=\"javascript:Oosp_TurnOverPage( "+(pageNo-1)+",'"+id+"') \">&laquo;&nbsp;上一页</a></li>\r\n";
				}
				
				// 下一页处理
				if (pageNo == pageTotal) {
					str+="<li class=\"disabled\"><a href=\"#\">下一页 »</a></li>\r\n";
				} else {
					str+="<li><a href=\"javascript:Oosp_TurnOverPage("+(pageNo + 1)+",'"+id+"')\">下一页&nbsp;&raquo;</a></li>\r\n";
				}
				
				str+="  </ul>\r\n";
				$("#"+id).append("<div class='Paging'>" +
							            " <div class='col-xs-6'>" +
							                 "<ul class='pagination'>" +str+
							                  "</ul>" +
							            " </div>" +
							            " <div class='col-xs-6'>" +
							                 " <div class='pull-right'>" +
							                 "      <span class='Paging_2'>第"+pageNo+"页</span>&nbsp;&nbsp;" +
							                 "      <span class='Paging_2'>共"+pageTotal+"页</span>" +
							                 "      <span>到</span><input class='form-control_1 input-sm input-goto MaoYe-form-TiaoZhuan' name='gotoPageNo' id='gotoPage"+id+"' type='text'>" +
							                 "      <a class='btn btn-default btn-sm Paging_3' href=\"javascript:Oosp_GoTo('"+id+"')\" role='button'>跳转</a>" +
							                 " </div>" +
							             "</div>" +
							        "</div>");
				$("#pageNo"+id).val(pageNo);
				$("#pageSize"+id).val(pageSize);  
			});   
   		}
   		 
   		
   		function Oosp_TurnOverPage(pageNo,id){ 
   			$("#pageNo"+id).val(pageNo); 
   			var messageType=0;
   			var history_bz="N";
   			if(id=="todoMessageDB"){
   				messageType=1;
   			}
   			if(id=="todoReadDB"){
   				messageType=2;
   			}
   			if(id=="todofinishDB"){
   				history_bz="Y";
   			} 
   			getTodoData(messageType,id,history_bz);  
   		}
   		
   		function Oosp_GoTo(id){ 
   			var val = $("#gotoPage"+id).val(); 
   			if(val!="" && val*1>0){ 
   				Oosp_TurnOverPage(val,id);
   			}else{	
   				return false;
   			}
   		}
   		 
   		
		//点击阅读待办事件
		function btn_read(messageType){  
			if(messageType.trim()=="2"){ 
				//刷新待阅读
				setTimeout(1000);
				getTodoData(2,"todoReadDB",'N');
				$('#todoRead').tab('show'); 
			}
		}
		var todoMessage_boolean=true;
		//待办
		function todoMessage_onclick(){
			if(todoMessage_boolean){ 
				//待办
				getTodoData(1,"todoMessageDB",'N');
				todoMessage_boolean=false;
			}
		}
		var todoRead_boolean=true;
		function todoRead_onclick(){
			if(todoRead_boolean){
				//待阅读
				getTodoData(2,"todoReadDB",'N');
				todoRead_boolean=false;
			}
		}
		
		var todofinish_boolean=true;
		function todofinish_onclick(){
			if(todofinish_boolean){
				//已办
				getTodoData(0,"todofinishDB",'Y'); 
				todofinish_boolean=false;
			}
		}